<select onchange="<?php echo  selectAction('id')?>" style="width: 150px;">
    <option value="0"><?echo getLang('Select category')?></option>
    <?php echo ListOptionParentProduct($id)?>
</select>

<?php echo inputSearch(getLang('search product'))?>
<?php echo buttonResetPage()?>

<form method="post" name="form_admin" action="<?php echo formAction('updatestatus')?>">
<input type="hidden" name="id" value="<?echo $id?>" />
	<table width="100%"  cellpadding="4" cellspacing="1" id="tblsort">
		<tr class="headtb" nodrop="true" nodrag="true">
			<td width="5%" ><?echo getLang('Order')?></td>
            <td width="5%"><?php echo inputCheckAll()?></td>
			<td width="5%" ><?echo getLang('Code')?></td>
			<td width="200" ><?php echo getLang('Product Name')?></td>
			<td width="140" ><?echo getLang('Price')?></td>
			<td width="10%" ><?php echo getLang('View')?></td>
			<td width="10%" ><?echo getLang('Depository')?></td>
			<td width="5%" ><?echo getLang('Status')?></td>
			<td width="5" ><?echo getLang('Actions')?></td>
			<td><?php echo getLang('Typical')?><br /><?php echo inputCheckAll('typical')?></td>
            <td><?php echo getLang('New')?><br /><?php echo inputCheckAll('new')?></td>
            <td><?php echo getLang('Hot')?><br /><?php echo inputCheckAll('hot')?></td>
		</tr>
	<?
	foreach($contents as $i => $content)
	{
	?>
	<tr>
		<td align=center>
			<input class="ordertext" id="listorder_<?php echo $i?>" name="listorder[]" value="<?echo getOrderList($i)?>">
		</td>
        <td align="center"><?php echo inputCheck($content['iId'])?></td>
		<td>
			<?echo $content['cCode']?>
		</td>
		<td nowrap="nowrap">
            <?php echo linkAction('edit',$content["cName"],'id='.$content["iId"])?>
		<input type="hidden" name="listid[]" value="<?echo $content["iId"]?>" />
		</td>
		<td align="right" nowrap>
			<input type="text" class="noedit" name="listprice[]" style="width:100px;text-align:right" value="<?echo $content['cPrice']?>">
			<?echo getconfig("UnitInput")?>
		</td>
		<td align="right">
			<?echo $content['iCountView']?>
		</td>
		<td align="right">
            <select name="listDep[]" id="listDep_<?php echo $i ?>">
                <?php echo  liststatus($content["iDepository"]);?>
            </select>
		</td>
		<td align=center>
			<select name="liststatus[]" id="liststatus_<?php echo $i ?>">
				<?php echo  liststatus($content["iStatus"]);?>
			</select>
		</td>
		<td align=center nowrap >
            <?php echo linkAction('photos',getLang('Photo'),'id='.$content["iId"])?> - 
            <?php echo linkAction('edit',getLang('Edit'),'id='.$content["iId"])?> - 
            <?php echo linkAction('delete',getLang('delete'),'id='.$content["iId"])?>
		</td>
		<td align="center"><?php echo CheckBoolean('typical',$content['iTypical'],true)?></td>
        <td align="center"><?php echo CheckBoolean('new',$content['iNew'],true)?></td>
        <td align="center"><?php echo CheckBoolean('hot',$content['iHot'],true)?></td>
		</tr>
	<?php
	}
	?>	
	</table>
</form>
<?php echo $show_page?>

<script type="text/javascript">
(new TableDnD).init("tblsort");
</script>